package com.gite.nouette.admin.implementation.service;

import java.util.HashMap;
import java.util.Map;

public class Meta<R> {
	private Class<?> clazz;
	private Map<String, Meta<?>> propertyMetaMap;

	public Meta(Class<?> clazz) {
		setClazz(clazz);
		setPropertyMetaMap(new HashMap<String, Meta<?>>());
	}

	/* GETTERS & SETTERS */

	public Class<?> getClazz() {
		return clazz;
	}

	public void setClazz(Class<?> clazz) {
		this.clazz = clazz;
	}

	public Map<String, Meta<?>> getPropertyMetaMap() {
		return propertyMetaMap;
	}

	public void setPropertyMetaMap(Map<String, Meta<?>> propertyMetaMap) {
		this.propertyMetaMap = propertyMetaMap;
	}

	public Meta<?> getMeta(String property) {
		return getPropertyMetaMap().get(property);
	}

	public void putPropertyMeta(String property, Meta<?> meta) {
		getPropertyMetaMap().put(property, meta);
	}
}
